Telephone Manager Initialization Summary
C Summary
Constants
Gestalt Selector and Response Values
enum { gestaltTeleMgrAttr = 'tele', gestaltTeleMgrPresent = 0, gestaltTeleMgrPowerPCSupport = 1, gestaltTeleMgrSoundStreams = 2, gestaltTeleMgrAutoAnswer = 3, gestaltTeleMgrIndHandset = 4, gestaltTeleMgrSilenceDetect = 5, gestaltTeleMgrNewTELNewSupport= 6 };Telephone Tool File Type
enum { classTEL = 'vbnd' };Telephone Manager Version
enum { curTELVersion = 4 };Telephone Record Flags
enum { telNoMenus = 1L << 16, telQuiet = 1L << 17, telConfigChanged = 1L << 18 };Handle Types
enum { telHandleType = 0, telDNHandleType = 1, telCAHandleType = 2 };Tool Choosing Result Codes
enum { telChooseDisaster = chooseDisaster, telChooseFailed = chooseFailed, telChooseAborted = chooseAborted, telChooseOKMinor = chooseOKMinor, telChooseOKMajor = chooseOKMajor, telChooseCancel = chooseCancel, telChooseOKTermChanged = 4 };Data Types
typedef OSErr TELErr; typedef unsigned long TELFlags; typedef unsigned long TELFeatureFlags;Telephone Record
struct TELRecord { short procID; TELFlags flags; short reserved; long refCon; long userData; UniversalProcPtr defproc; Ptr config; Ptr oldConfig; TELTermPtr pTELTerm; long telPrivate; long reserved1; long reserved2; long pTELTermSize; short version; }; typedef struct TELRecord TELRecord; typedef TELRecord *TELPtr, **TELHandle;Feature List Structure
struct FeatureList { short featureID; StringPtr featureName; short handleType; struct FeatureList *nextFeature; }; typedef struct FeatureList FeatureList; typedef FeatureList *FeatureListPtr;Telephone Manager Initialization Functions
Initializing the Telephone Manager
pascal TELErr InitTEL (void); pascal short TELGetTELVersion (void);Obtaining Tool IDs
pascal short TELGetProcID (Str255 name);Creating, Initializing, and Validating a Telephone Record
pascal TELHandle TELNewWithResult(short procID, TELFlags flags, long refCon, long userData, TELErr *error); pascal TELHandle TELNew (short procID, TELFlags flags, long refCon, long userData); pascal TELErr TELGetTelNewErr (void); pascal TELErr TELDefault (Ptr *theConfig, short procID, Boolean allocate); pascal Boolean TELValidate (TELHandle hTEL);Configuring a Telephone Tool with the Standard Interface
pascal TELErr TELChoose (TELHandle *hTEL, Point where, TelephoneChooseIdleUPP idleProc);Configuring a Telephone Tool with a Custom Interface
pascal Handle TELSetupPreflight (short procID, long *magicCookie); pascal void TELSetupSetup (short procID, Ptr theConfig, short count, DialogPtr theDialog, long *magicCookie); pascal Boolean TELSetupFilter (short procID, Ptr theConfig, short count, DialogPtr theDialog, EventRecord *theEvent, short *theItem, long *magicCookie); pascal void TELSetupItem (short procID, Ptr theConfig, short count, DialogPtr theDialog, short *theItem, long *magicCookie); pascal void TELSetupCleanup (short procID, Ptr theConfig, short count, DialogPtr theDialog, long *magicCookie); pascal void TELSetupXCleanup (short procID, Ptr theConfig, short count, DialogPtr theDialog, Boolean OKed, long *magicCookie); pascal void TELSetupPostflight (short procID);Configuring a Telephone Tool Through a Scripting Language
pascal Ptr TELGetConfig (TELHandle hTEL); pascal short TELSetConfig (TELHandle hTEL, Ptr thePtr); pascal TELErr TELIntlToEnglish (TELHandle hTEL, Ptr inputPtr, Ptr *outputPtr, short language); pascal TELErr TELEnglishToIntl (TELHandle hTEL, Ptr inputPtr, Ptr *outputPtr, short language);Working With a Telephone Tool
pascal void TELGetToolName (short procID, Str255 name); pascal Handle TELGetVersion (TELHandle hTEL); pascal TELErr TELToolFunctions (TELHandle hTEL, short msgcode, Boolean *supportsIt); pascal TELErr TELOtherFeatureList(TELHandle hTEL, FeatureListPtr *fList); pascal TELErr TELOtherFeatureImplement ( TELHandle hTEL, Handle theHandle, short featureID); pascal TELErr TELOtherFunction (TELHandle hTEL, Ptr paramblock, long size);Passing Events to a Telephone Tool for Processing
pascal void TELActivate (TELHandle hTEL, Boolean activate); pascal void TELResume (TELHandle hTEL, Boolean resume); pascal Boolean TELMenu (TELHandle hTEL, short menuID, short item); pascal void TELEvent (TELHandle hTEL, const EventRecord *theEvent);Pascal Summary
Constants
Gestalt Selector and Response Values
CONST gestaltTeleMgrAttr = 'tele'; gestaltTeleMgrPresent = 0; gestaltTeleMgrPowerPCSupport = 1; gestaltTeleMgrSoundStreams = 2; gestaltTeleMgrAutoAnswer = 3; gestaltTeleMgrIndHandset = 4; gestaltTeleMgrSilenceDetect = 5; gestaltTeleMgrNewTELNewSupport = 6;Telephone Tool File Type
CONST classTEL = 'vbnd';Telephone Manager Version
CONST curTELVersion = 4;Telephone Record Flags
CONST telNoMenus = $00010000; telQuiet = $00020000; telConfigChanged = $00040000;Handle Types
CONST telHandleType = 0; telDNHandleType = 1; telCAHandleType = 2;Tool Choosing Result Codes
CONST telChooseDisaster = chooseDisaster; telChooseFailed = chooseFailed; telChooseAborted = chooseAborted; telChooseOKMinor = chooseOKMinor; telChooseOKMajor = chooseOKMajor; telChooseCancel = chooseCancel; telChooseOKTermChanged = 4;Data Types
TYPE TELErr = OSErr; TELFlags = LongInt; TELFeatureFlags = LongInt;Telephone Record
TELRecord = RECORD procID: Integer; flags: TELFlags; reserved: Integer; refCon: LongInt; userData: LongInt; defproc: ProcPtr; config: Ptr; oldConfig: Ptr; pTELTerm: TELTermPtr; telPrivate: LongInt; reserved1: LongInt; reserved2: LongInt; pTELTermSize: LongInt; version: Integer; END; TELHandle = ^TELPtr; TELPtr = ^TELRecord;Feature List Structure
FeatureList = RECORD featureID: Integer; featureName: StringPtr; handleType: Integer; nextFeature: FeatureListPtr END; FeatureListPtr = ^FeatureList;Telephone Manager Initialization Functions
Initializing the Telephone Manager
FUNCTION InitTEL : TELErr; FUNCTION TELGetTELVersion : Integer;Obtaining Tool IDs
FUNCTION TELGetProcID (rmtName: Str255): Integer;Creating, Initializing, and Validating a Telephone Record
FUNCTION TELNewWithResult (procID: Integer; flags: TELFlags; refCon: LongInt; userData: LongInt; VAR error: Integer): TELHandle; FUNCTION TELNew (procID: Integer; flags: TELFlags; refCon: LongInt; userData: LongInt): TELHandle; FUNCTION TELGetTelNewErr : Integer; FUNCTION TELDefault (VAR theConfig: Ptr; procID: Integer; allocate: Boolean): TELErr; FUNCTION TELValidate (hTEL: TELHandle): Boolean;Configuring a Telephone Tool with the Standard Interface
FUNCTION TELChoose (VAR hTEL: TELHandle; where: Point; idleProc: ProcPtr): TELErr;Configuring a Telephone Tool with a Custom Interface
FUNCTION TELSetupPreflight (procID: Integer; VAR magicCookie: LongInt): Handle; PROCEDURE TELSetupSetup (procID: Integer; theConfig: Ptr; count: Integer; theDialog: DialogPtr; VAR magicCookie: LongInt); FUNCTION TELSetupFilter (procID: Integer; theConfig: Ptr; count: Integer; theDialog: DialogPtr; VAR theEvent: EventRecord; VAR theItem: Integer; VAR magicCookie: LongInt): BOOLEAN; PROCEDURE TELSetupItem (procID: Integer; theConfig: Ptr; count: Integer; theDialog: DialogPtr; VAR theItem: Integer; VAR magicCookie: LongInt); PROCEDURE TELSetupCleanup (procID: Integer; theConfig: Ptr; count: Integer; theDialog: DialogPtr; VAR magicCookie: LongInt); PROCEDURE TELSetupXCleanup (procID: Integer; theConfig: Ptr; count: Integer; theDialog: DialogPtr; OKed: Boolean; VAR magicCookie: LongInt); PROCEDURE TELSetupPostflight (procID: Integer);Configuring a Telephone Tool Through a Scripting Language
FUNCTION TELGetConfig (hTEL: TELHandle): Ptr; FUNCTION TELSetConfig (hTEL: TELHandle; thePtr: Ptr): Integer; FUNCTION TELIntlToEnglish (hTEL: TELHandle; inputPtr: Ptr; VAR outputPtr: Ptr; language: Integer): OSErr; FUNCTION TELEnglishToIntl (hTEL: TELHandle; inputPtr: Ptr; VAR outputPtr: Ptr; language: Integer): OSErr;Working With a Telephone Tool
PROCEDURE TELGetToolName (procID: Integer; VAR name: Str255); FUNCTION TELGetVersion (hTEL: TELHandle): Handle; FUNCTION TELToolFunctions (hTEL: TELHandle; msgcode: Integer; VAR supportsIt: Boolean): TELErr; FUNCTION TELOtherFeatureList (hTEL: TELHandle; VAR fList: FeatureListPtr): TELErr; FUNCTION TELOtherFeatureImplement(hTEL: TELHandle; theHandle: Handle; featureID: Integer): TELErr; FUNCTION TELOtherFunction (hTEL: TELHandle; paramblock: Ptr; size: LongInt): TELErr;Passing Events to a Telephone Tool for Processing
PROCEDURE TELActivate (hTEL: TELHandle; activate: Boolean); PROCEDURE TELResume (hTEL: TELHandle; resume: Boolean); FUNCTION TELMenu (hTEL: TELHandle; menuID: Integer; item: Integer): Boolean; PROCEDURE TELEvent (hTEL: TELHandle; VAR theEvent: EventRecord);
![]()
![]()
![]()
![]()
© Apple Computer, Inc.
13 DEC 1996Main | Top of Section | What's New | Apple Computer, Inc. | Find It | Feedback | Help